<?php 
	$objConvert  		= new HT_Model_administrator_models_convert();
	$objUtil  			= new HT_Model_administrator_models_utility();
	$info 				= $this->info;
	$news 				= $info['news'];
	$relatedNews		= $info['relatedNews'];
	$topNews			= $info['topNews'];
	$newsTitle 			= stripcslashes($news['title']);
	$newsPath 			= ROOT_PATH."/public/uploads/news/".$news['image'];
	$newsImageUrl		= null;
	if(is_file($newsPath)){
		$newsImageUrl	= WEB_PATH."/public/uploads/news/".$news['image'];
	}
	$newsDescription 	= trim(stripcslashes($news['description']));
	$content 			= trim($news['content']);
?>
<div class="column1 fl">
	<div class="news_detail_title"><h1><?php echo $newsTitle;?><h1></div>
	<ul class="news_related">
		<?php foreach((array)$relatedNews as $news){
			$newsTitle 			= stripcslashes($news['title']);
			$newsUrl			= WEB_PATH.'/chi-tiet/'.$objConvert->utf8_to_url($newsTitle).'-'.$news['news_id'].'.html';
		?>
		<li><a alt="<?php echo $newsTitle;?>" title="<?php echo $newsTitle;?>" href="<?php echo $newsUrl;?>"><?php echo $newsTitle;?></a></li>
		<?php }?>
	</ul>
	<div class="news_detail_description"><?php echo $newsDescription;?></div>
	<div class="news_detail_content">
		<?php 
			if($newsImageUrl) echo '<div class="news_detail_image fl"><img src="'.$newsImageUrl.'"></div>';
			echo stripcslashes($content);
		?>
		<div class="cb"></div>
	</div>
</div>
<div class="column2 fl">
	<?php echo $this->action('rightadv4','elements','front');?>
	<?php echo $this->action('rightadv1','elements','front');?>
	<div class="top_news_list">
		<div class="hot_news_list_header">Những bài được xem nhiều nhất</div>
		<?php 
			foreach((array)$topNews as $news){
				$newsTitle 			= stripcslashes($news['title']);
				$newsPath 			= ROOT_PATH."/public/uploads/news/".$news['image'];
				$newsImageUrl		= null;
				if(is_file($newsPath)){
					$newsImageUrl	= WEB_PATH."/public/uploads/news/".$news['image'];
				}
				$newsDescription 	= $objUtil->tooltipString(trim(stripcslashes($news['description'])),70);
				$newsUrl			= WEB_PATH.'/chi-tiet/'.$objConvert->utf8_to_url($newsTitle).'-'.$news['news_id'].'.html';
		?>
		<div class="top_item_info">
			<?php if($newsImageUrl) echo '<div class="top_item_image fl"><img alt="" src="'.$newsImageUrl.'"></div>'; ?>
			<a alt="<?php echo $newsTitle;?>" title="<?php echo $newsTitle;?>" href="<?php echo $newsUrl;?>"><?php echo $newsTitle;?></a>
			<p><?php echo $newsDescription;?></p>
			<div class="cb"></div>
		</div>
		<div class="cb"></div>
		<?php } ?>
	</div>
	<?php //echo $this->action('rightadv2','elements','front');?>
</div>
<div class="cb"></div>